#define  _CRT_SECURE_NO_WARNINGS 1
int findMaxConsecutiveOnes(int* nums, int numsSize) 
{
	int i = 0;
	int a = 0, max = 0;
	for (i = 0; i < numsSize; i++)
	{
		if (nums[i])
			a++;
		else
		{
			max = max > a ? max : a;
			a = 0;
		}
	}
	max = max > a ? max : a;
	return max;
}